[gd_resource type="ShaderMaterial" load_steps=31 format=2]

[ext_resource path="res://entities/player/Playersphere_normal.png" type="Texture" id=1]
[ext_resource path="res://entities/player/Playersphere_roughness.png" type="Texture" id=2]
[ext_resource path="res://entities/player/Playersphere_color_blue.png" type="Texture" id=3]

[sub_resource type="VisualShaderNodeScalarOp" id=4]
default_input_values = [ 0, 1.0, 1, 0.0 ]
operator = 2

[sub_resource type="VisualShaderNodeColorUniform" id=11]
output_port_for_preview = 0
uniform_name = "GlowColorOff"

[sub_resource type="VisualShaderNodeInput" id=13]
input_name = "uv"

[sub_resource type="VisualShaderNodeTexture" id=14]
texture = ExtResource( 1 )
texture_type = 2

[sub_resource type="VisualShaderNodeTexture" id=15]
texture = ExtResource( 2 )

[sub_resource type="VisualShaderNodeScalarConstant" id=16]
constant = 1.0

[sub_resource type="VisualShaderNodeInput" id=6]
input_name = "normal"

[sub_resource type="VisualShaderNodeInput" id=17]
input_name = "uv"

[sub_resource type="VisualShaderNodeScalarOp" id=18]
default_input_values = [ 0, -0.57, 1, 0.0 ]

[sub_resource type="VisualShaderNodeScalarOp" id=19]
default_input_values = [ 0, 2.4, 1, 0.0 ]
operator = 2

[sub_resource type="VisualShaderNodeScalarOp" id=20]
default_input_values = [ 0, 0.0, 1, 1.0 ]
operator = 5

[sub_resource type="VisualShaderNodeInput" id=22]
input_name = "view"

[sub_resource type="VisualShaderNodeVectorFunc" id=23]

[sub_resource type="VisualShaderNodeScalarUniform" id=24]
uniform_name = "GlowStrength"

[sub_resource type="VisualShaderNodeScalarFunc" id=25]
function = 19

[sub_resource type="VisualShaderNodeScalarOp" id=26]
default_input_values = [ 0, 1.0, 1, 0.0 ]

[sub_resource type="VisualShaderNodeScalarUniform" id=27]
uniform_name = "GlowFactor"

[sub_resource type="VisualShaderNodeTextureUniform" id=28]
uniform_name = "base_tex"
texture_type = 1

[sub_resource type="VisualShaderNodeScalarUniform" id=29]
uniform_name = "Glowing"

[sub_resource type="VisualShaderNodeColorUniform" id=30]
output_port_for_preview = 0
uniform_name = "GlowColorOn"

[sub_resource type="VisualShaderNodeVectorInterp" id=31]
default_input_values = [ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ), 2, Vector3( 1, 1, 1 ) ]

[sub_resource type="VisualShaderNodeVectorInterp" id=32]
default_input_values = [ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ), 2, Vector3( 1, 1, 1 ) ]

[sub_resource type="VisualShaderNodeColorConstant" id=33]
constant = Color( 0, 0, 0, 1 )

[sub_resource type="VisualShaderNodeScalarOp" id=34]
default_input_values = [ 0, 0.0, 1, 0.2 ]
operator = 2

[sub_resource type="VisualShaderNodeDotProduct" id=7]

[sub_resource type="VisualShaderNodeVectorInterp" id=9]
default_input_values = [ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ), 2, Vector3( 1, 1, 1 ) ]

[sub_resource type="VisualShader" id=1]
code = "shader_type spatial;
uniform sampler2D base_tex : hint_albedo;
uniform vec4 GlowColorOff : hint_color;
uniform vec4 GlowColorOn : hint_color;
uniform float Glowing;
uniform float GlowStrength;
uniform float GlowFactor;
uniform sampler2D tex_frg_18;uniform sampler2D tex_frg_17 : hint_normal;


void vertex() {
// Output:0

}

void fragment() {
// Input:16
	vec3 n_out16p0;
	n_out16p0 = vec3(UV,0.0);

// TextureUniform:32
	vec3 n_out32p0;
	float n_out32p1;
	{
		vec4 n_tex_read = texture( base_tex , n_out16p0.xy );
		n_out32p0 = n_tex_read.rgb;
		n_out32p1 = n_tex_read.a;
	}

// ColorUniform:14
	vec3 n_out14p0;
	float n_out14p1;
	n_out14p0 = GlowColorOff.rgb;
	n_out14p1 = GlowColorOff.a;

// ColorUniform:34
	vec3 n_out34p0;
	float n_out34p1;
	n_out34p0 = GlowColorOn.rgb;
	n_out34p1 = GlowColorOn.a;

// ScalarUniform:33
	float n_out33p0;
	n_out33p0 = Glowing;

// VectorInterp:35
	vec3 n_out35p0;
	n_out35p0 = mix( n_out14p0 , n_out34p0 , vec3(n_out33p0) );

// ScalarUniform:27
	float n_out27p0;
	n_out27p0 = GlowStrength;

// Input:2
	vec3 n_out2p0;
	n_out2p0 = NORMAL;

// Input:25
	vec3 n_out25p0;
	n_out25p0 = VIEW;

// VectorFunc:26
	vec3 n_out26p0;
	n_out26p0=normalize(n_out25p0);

// DotProduct:5
	float n_out5p0;
	n_out5p0 = dot( n_out2p0 , n_out26p0 );

// ScalarUniform:30
	float n_out30p0;
	n_out30p0 = GlowFactor;

// ScalarOp:23
	float n_out23p0;
	n_out23p0 = pow( n_out5p0 , n_out30p0 );

// ScalarFunc:28
	float n_out28p0;
	n_out28p0 = -(n_out23p0);

// ScalarOp:29
	float n_in29p0 = 1.00000;
	float n_out29p0;
	n_out29p0 = n_in29p0 + n_out28p0;

// ScalarOp:11
	float n_out11p0;
	n_out11p0 = n_out27p0 * n_out29p0;

// VectorInterp:7
	vec3 n_out7p0;
	n_out7p0 = mix( n_out32p0 , n_out35p0 , vec3(n_out11p0) );

// Input:20
	vec3 n_out20p0;
	n_out20p0 = vec3(UV,0.0);

// Texture:18
	vec3 n_out18p0;
	float n_out18p1;
	vec4 tex_frg_18_read = texture( tex_frg_18 , n_out20p0.xy );
	n_out18p0 = tex_frg_18_read.rgb;
	n_out18p1 = tex_frg_18_read.a;

// ScalarOp:22
	float n_in22p0 = 2.40000;
	float n_out22p0;
	n_out22p0 = n_in22p0 * dot(n_out18p0,vec3(0.333333,0.333333,0.333333));

// ScalarOp:21
	float n_in21p0 = -0.57000;
	float n_out21p0;
	n_out21p0 = n_in21p0 + n_out22p0;

// Color:37
	vec3 n_out37p0;
	float n_out37p1;
	n_out37p0 = vec3(0.000000,0.000000,0.000000);
	n_out37p1 = 1.000000;

// ScalarOp:38
	float n_in38p1 = 0.20000;
	float n_out38p0;
	n_out38p0 = n_out33p0 * n_in38p1;

// VectorInterp:36
	vec3 n_out36p0;
	n_out36p0 = mix( n_out37p0 , n_out14p0 , vec3(n_out38p0) );

// Texture:17
	vec3 n_out17p0;
	float n_out17p1;
	vec4 tex_frg_17_read = texture( tex_frg_17 , n_out20p0.xy );
	n_out17p0 = tex_frg_17_read.rgb;
	n_out17p1 = tex_frg_17_read.a;

// Scalar:19
	float n_out19p0;
	n_out19p0 = 1.000000;

// Output:0
	ALBEDO = n_out7p0;
	ROUGHNESS = n_out21p0;
	EMISSION = n_out36p0;
	NORMALMAP = n_out17p0;
	NORMALMAP_DEPTH = n_out19p0;

}

void light() {
// Output:0

}
"
graph_offset = Vector2( -203.427, -129.92 )
nodes/fragment/0/position = Vector2( 600, 140 )
nodes/fragment/2/node = SubResource( 6 )
nodes/fragment/2/position = Vector2( -740, 100 )
nodes/fragment/5/node = SubResource( 7 )
nodes/fragment/5/position = Vector2( -520, 100 )
nodes/fragment/7/node = SubResource( 9 )
nodes/fragment/7/position = Vector2( 440, -120 )
nodes/fragment/11/node = SubResource( 4 )
nodes/fragment/11/position = Vector2( 260, 0 )
nodes/fragment/14/node = SubResource( 11 )
nodes/fragment/14/position = Vector2( -160, -700 )
nodes/fragment/16/node = SubResource( 13 )
nodes/fragment/16/position = Vector2( -240, -220 )
nodes/fragment/17/node = SubResource( 14 )
nodes/fragment/17/position = Vector2( 220, 340 )
nodes/fragment/18/node = SubResource( 15 )
nodes/fragment/18/position = Vector2( -220, 260 )
nodes/fragment/19/node = SubResource( 16 )
nodes/fragment/19/position = Vector2( 200, 560 )
nodes/fragment/20/node = SubResource( 17 )
nodes/fragment/20/position = Vector2( -480, 440 )
nodes/fragment/21/node = SubResource( 18 )
nodes/fragment/21/position = Vector2( 260, 180 )
nodes/fragment/22/node = SubResource( 19 )
nodes/fragment/22/position = Vector2( 20, 220 )
nodes/fragment/23/node = SubResource( 20 )
nodes/fragment/23/position = Vector2( -320, 60 )
nodes/fragment/25/node = SubResource( 22 )
nodes/fragment/25/position = Vector2( -940, 200 )
nodes/fragment/26/node = SubResource( 23 )
nodes/fragment/26/position = Vector2( -760, 200 )
nodes/fragment/27/node = SubResource( 24 )
nodes/fragment/27/position = Vector2( -220, -100 )
nodes/fragment/28/node = SubResource( 25 )
nodes/fragment/28/position = Vector2( -240, -20 )
nodes/fragment/29/node = SubResource( 26 )
nodes/fragment/29/position = Vector2( -20, 0 )
nodes/fragment/30/node = SubResource( 27 )
nodes/fragment/30/position = Vector2( -600, -220 )
nodes/fragment/32/node = SubResource( 28 )
nodes/fragment/32/position = Vector2( 20, -260 )
nodes/fragment/33/node = SubResource( 29 )
nodes/fragment/33/position = Vector2( -460, -400 )
nodes/fragment/34/node = SubResource( 30 )
nodes/fragment/34/position = Vector2( -160, -480 )
nodes/fragment/35/node = SubResource( 31 )
nodes/fragment/35/position = Vector2( 280, -400 )
nodes/fragment/36/node = SubResource( 32 )
nodes/fragment/36/position = Vector2( 660, -480 )
nodes/fragment/37/node = SubResource( 33 )
nodes/fragment/37/position = Vector2( 480, -320 )
nodes/fragment/38/node = SubResource( 34 )
nodes/fragment/38/position = Vector2( 420, -540 )
nodes/fragment/connections = PoolIntArray( 2, 0, 5, 0, 7, 0, 0, 0, 17, 0, 0, 8, 19, 0, 0, 9, 20, 0, 17, 0, 20, 0, 18, 0, 18, 0, 22, 1, 22, 0, 21, 1, 25, 0, 26, 0, 26, 0, 5, 1, 5, 0, 23, 0, 23, 0, 28, 0, 28, 0, 29, 1, 29, 0, 11, 1, 11, 0, 7, 2, 27, 0, 11, 0, 30, 0, 23, 1, 16, 0, 32, 0, 32, 0, 7, 0, 14, 0, 35, 0, 34, 0, 35, 1, 33, 0, 35, 2, 35, 0, 7, 1, 37, 0, 36, 0, 14, 0, 36, 1, 36, 0, 0, 5, 33, 0, 38, 0, 38, 0, 36, 2, 21, 0, 0, 3 )

[resource]
shader = SubResource( 1 )
shader_param/GlowColorOff = Color( 0.160784, 0.172549, 1, 1 )
shader_param/GlowColorOn = Color( 0.780392, 0.784314, 1, 1 )
shader_param/Glowing = 0.0
shader_param/GlowStrength = 4.0
shader_param/GlowFactor = 0.2
shader_param/base_tex = ExtResource( 3 )
